//
//  Item.h
//  yuimall_Iphone
//
//  Created by yuike6 yuike6 on 12-4-16.
//  Copyright (c) 2012年 yuike. All rights reserved.
//


/*
 Item(商品)结构
 http ://api.taobao.com/apidoc/dataStruct.htm?path=cid:4-dataStructId:63-apiId:20-invokePath:item
 */
#import "TopRecvXml.h"
#import "Location.h"
#import "ItemImg.h"
#import "PropImg.h"
#import "Video.h"
#import "Price.h"

@interface Item : TopRecvXml
{
    NSString * detail_url;     //商品url
    NSString * num_iid;         //商品数字id
    
    NSString * title;           //商品标题,不能超过60字节
    NSString * nick;            //卖家昵称
    
    NSString * type;            //商品类型(fixed:一口价;auction:拍卖)注：取消团购
    NSString * desc;
    
    // Sku * sku list
    NSString * props_name;  //商品属性名称
    NSDate * created;
    
    BOOL is_lightning_consignment;
    NSNumber *  is_fenxiao;         //非分销商品：0，代销：1，经销：2
    
    NSString * auction_point;           //商城返点比例，为5的倍数，最低0.5%
    NSString * property_alias;      //属性值别名,比如颜色的自定义名称
    
    NSString * template_id;
    NSString * after_sale_id;           //售后服务ID,该字段仅在taobao.item.get接口中返回
    
    BOOL is_xinpin;           //标示商品是否为新品。 值含义：true-是，false-否
    NSNumber * sub_stock;        //标识商品减库存的方式 值含义：1-拍下减库存，2-付款减库存。
    
    NSString * inner_shop_auction_template_id;
    NSString * outer_shop_auction_template_id;
    
    NSNumber * cid;                //商品所属的叶子类目 id
    NSString * seller_cids;     //商品所属的店铺内卖家自定义类目列表
        
    NSString * props;
    NSString * input_pids;
    
    NSString * input_str;
    NSString * pic_url;         //商品主图片地址    （ ===>  重要  <=== ）
    
    NSNumber * num;              //商品数量
    NSNumber * valid_thru;       // 有效期,7或者14（默认是14天）
    
    NSDate * list_time;         //上架时间
    NSDate * delist_time;       //下架时间（格式：yyyy-MM-dd HH:mm:ss）
    
    NSString * stuff_status;        //商品新旧程度(全新:new，闲置:unused，二手：second)
    Location * location;                  //商品所在地
    
    
    Price * price;
    Price * post_fee;                       //平邮费用
    
    Price * express_fee;                    // 快递费用
    Price * ems_fee;                        // ems费用
    
    BOOL has_discount;                      //支持会员打折,true/false
    NSString * freight_payer;               //运费承担方式,seller（卖家承担），buyer(买家承担）
    
    BOOL has_invoice;                       //是否有发票,true/false
    BOOL has_warranty;                      //是否有保修,true/false
    
    BOOL has_showcase;
    NSDate * modified;
    
    NSString * increment;                   //加价幅度。
    BOOL approve_status;                    //商品上传后的状态。onsale出售中，instock库中
    
    NSNumber * postage_id;
    NSNumber * product_id;                  //宝贝所属产品的id(可能为空). 该字段可以通过taobao.products.search 得到
    /* ItemImg */ NSMutableArray * item_imgs;  //商品图片列表(包括主图)
    
    /*PropImg*/  NSMutableArray * prop_imgs;    
    NSString * outer_id;                    //商家外部编码(可与商家外部系统对接)
    
    BOOL is_virtual;                        //虚拟商品的状态字段
    BOOL is_taobao;                         //是否在淘宝显示
    
    BOOL is_ex;                             //是否在外部网店显示
    BOOL is_timing;                         //是否定时上架商品
    
    /*Video*/ NSMutableArray * videos;                      //商品视频列表(
    BOOL is_3D;                             //是否是3D淘宝的商品
    
    BOOL one_station;                       //是否淘1站商品
    NSString * second_kill;                 //秒杀商品类型。
    
    NSString * auto_fill;                   //代充商品类型
    BOOL violation;                         //商品是否违规，违规：true , 不违规：false
    
    NSString * wap_desc;                    //Wap宝贝详情
    NSString * wap_detail_url;              //适合wap应用的商品详情url ，该字段只在taobao.item.get接口中返回
    
    NSNumber * cod_postage_id;
    BOOL sell_promise;                      //是否承诺退换货服务!
}

@property (nonatomic, strong) NSString *detail_url;
@property (nonatomic, strong) NSString *num_iid;

@property (nonatomic, strong) NSString *title;
@property (nonatomic, strong) NSString *nick;

@property (nonatomic, strong) NSString *type;
@property (nonatomic, strong) NSString *desc;

@property (nonatomic, strong) NSString *props_name;
@property (nonatomic, strong) NSDate *created;

@property (nonatomic, assign) BOOL is_lightning_consignment;
@property (nonatomic, strong) NSNumber *is_fenxiao;

@property (nonatomic, strong) NSString *auction_point;
@property (nonatomic, strong) NSString *property_alias;

@property (nonatomic, strong) NSString *template_id;
@property (nonatomic, strong) NSString *after_sale_id;

@property (nonatomic, assign) BOOL is_xinpin;
@property (nonatomic, strong) NSNumber *sub_stock;

@property (nonatomic, strong) NSString *inner_shop_auction_template_id;
@property (nonatomic, strong) NSString *outer_shop_auction_template_id;

@property (nonatomic, strong) NSNumber *cid;
@property (nonatomic, strong) NSString *seller_cids;

@property (nonatomic, strong) NSString *props;
@property (nonatomic, strong) NSString *input_pids;

@property (nonatomic, strong) NSString *input_str;
@property (nonatomic, strong) NSString *pic_url;

@property (nonatomic, strong) NSNumber *num;
@property (nonatomic, strong) NSNumber *valid_thru;

@property (nonatomic, strong) NSDate *list_time;
@property (nonatomic, strong) NSDate *delist_time;

@property (nonatomic, strong) NSString *stuff_status;
@property (nonatomic, strong) Location *location;

@property (nonatomic, strong) Price *price;
@property (nonatomic, strong) Price *post_fee;

@property (nonatomic, strong) Price *express_fee;
@property (nonatomic, strong) Price *ems_fee;

@property (nonatomic, assign) BOOL has_discount;
@property (nonatomic, strong) NSString *freight_payer;

@property (nonatomic, assign) BOOL has_invoice;
@property (nonatomic, assign) BOOL has_warranty;

@property (nonatomic, assign) BOOL has_showcase;
@property (nonatomic, strong) NSDate *modified;

@property (nonatomic, strong) NSString *increment;
@property (nonatomic, assign) BOOL approve_status;

@property (nonatomic, strong) NSNumber *postage_id;
@property (nonatomic, strong) NSNumber *product_id;

@property (nonatomic, strong) NSMutableArray * item_imgs;
@property (nonatomic, strong) NSMutableArray * prop_imgs;

@property (nonatomic, strong) NSString *outer_id;
@property (nonatomic, assign) BOOL is_virtual;

@property (nonatomic, assign) BOOL is_taobao;
@property (nonatomic, assign) BOOL is_ex;

@property (nonatomic, assign) BOOL is_timing;

@property (nonatomic, strong) NSMutableArray * videos;
@property (nonatomic, assign) BOOL is_3D;

@property (nonatomic, assign) BOOL one_station;
@property (nonatomic, strong) NSString *second_kill;

@property (nonatomic, strong) NSString *auto_fill;
@property (nonatomic, assign, getter=isViolation) BOOL violation;

@property (nonatomic, strong) NSString *wap_desc;
@property (nonatomic, strong) NSString *wap_detail_url;

@property (nonatomic, strong) NSNumber *cod_postage_id;
@property (nonatomic, assign, getter=isSell_promise) BOOL sell_promise;
@end































